package com.ruoyi.purchase.service.impl;

import java.util.List;

import com.ruoyi.purchase.mapper.FirmWarehouseMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.purchase.domain.FirmWarehouse;
import com.ruoyi.purchase.service.IFirmWarehouseService;

/**
 * 仓库管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-07-16
 */
@Service
public class FirmWarehouseServiceImpl implements IFirmWarehouseService 
{
    @Autowired
    private FirmWarehouseMapper firmWarehouseMapper;

    /**
     * 查询仓库管理
     * 
     * @param id 仓库管理主键
     * @return 仓库管理
     */
    @Override
    public FirmWarehouse selectFirmWarehouseById(Long id)
    {
        return firmWarehouseMapper.selectFirmWarehouseById(id);
    }

    /**
     * 查询仓库管理列表
     * 
     * @param firmWarehouse 仓库管理
     * @return 仓库管理
     */
    @Override
    public List<FirmWarehouse> selectFirmWarehouseList(FirmWarehouse firmWarehouse)
    {
        return firmWarehouseMapper.selectFirmWarehouseList(firmWarehouse);
    }

    /**
     * 新增仓库管理
     * 
     * @param firmWarehouse 仓库管理
     * @return 结果
     */
    @Override
    public int insertFirmWarehouse(FirmWarehouse firmWarehouse)
    {
        return firmWarehouseMapper.insertFirmWarehouse(firmWarehouse);
    }

    /**
     * 修改仓库管理
     * 
     * @param firmWarehouse 仓库管理
     * @return 结果
     */
    @Override
    public int updateFirmWarehouse(FirmWarehouse firmWarehouse)
    {
        return firmWarehouseMapper.updateFirmWarehouse(firmWarehouse);
    }

    /**
     * 批量删除仓库管理
     * 
     * @param ids 需要删除的仓库管理主键
     * @return 结果
     */
    @Override
    public int deleteFirmWarehouseByIds(Long[] ids)
    {
        return firmWarehouseMapper.deleteFirmWarehouseByIds(ids);
    }

    /**
     * 删除仓库管理信息
     * 
     * @param id 仓库管理主键
     * @return 结果
     */
    @Override
    public int deleteFirmWarehouseById(Long id)
    {
        return firmWarehouseMapper.deleteFirmWarehouseById(id);
    }
}
